home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++
- Message-ID: <4ejl6d$1ck@news00.btx.dtag.de>
- From: PHoersemann@t-online.de (Peter Hrsemann)
- Path: news00.btx.dtag.de!not-for-mail!PHoersemann
- Subject: Multithreading with BC4.5
- Date: Mon, 29 Jan 1996 22:28:13 +0000
- X-Gateway: ZCONNECT XX ius.gun.de [UNIX/Connect v0.73]
- MIME-Version: 1.0
- Content-Type: text/plain; charset=ISO-8859-1
- Content-Transfer-Encoding: 8bit
-
- Hello Folks !
-
- This is my first posting to a newsgroup and I hope to get plenty of
- feedback :-)
-
- My problem:
- I want to call a member function of an existing object as a background
- thread. Therefore I created a friend function in its class :
-
- void friendfunc(void* obj)
-
- , which is called by:
-
- _beginthread(friendfunc,4096,(void*)obj);
-
- In this friend function, I want to call a member function of obj.
- Because of its actual type void*, I have to do a type conversion.
- But how ?? What is the correct type conversion, so I am able to call
- obj.memberfunc ?
- Is there a complete different (better?) way to solve the whole problem
- ?
-
- Thanks, Peter Hoersemann, PHoersemann@t-online.de, Germany
-
-